package com.earthea.common.exception;

/**
 * 错误码枚举
 */
public enum ErrorCodeEnum implements IErrorCode {
    SUCCESS(0, "success"), FAIL(-1, "fail"),
    ;

    private final int code;

    private final String msg;

    ErrorCodeEnum(int code, String msg) {
        this.code = code;
        this.msg = msg;
    }

    public int getIntCode() {
        return code;
    }

    @Override
    public int getCode() {
        return code;
    }

    @Override
    public String getMsg() {
        return msg;
    }
}
